package com.ruoyi.domain.production;

import java.math.BigDecimal;
import java.util.Date;
import java.util.List;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.core.domain.BaseEntity;
import com.fasterxml.jackson.annotation.JsonFormat;

/**
 * 生产退料单对象 mes_production_return
 * 
 * @author ruoyi
 * @date 2024-01-01
 */
public class MesProductionReturn extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** 退料单ID */
    private Long returnId;

    /** 退料单号 */
    @Excel(name = "退料单号")
    private String returnCode;

    /** 原领料单ID */
    @Excel(name = "原领料单ID")
    private Long pickingId;

    /** 原领料单号 */
    @Excel(name = "原领料单号")
    private String pickingCode;

    /** 工单ID */
    @Excel(name = "工单ID")
    private Long workOrderId;

    /** 工单编号 */
    @Excel(name = "工单编号")
    private String workOrderCode;

    /** 退料日期 */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @Excel(name = "退料日期", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
    private Date returnDate;

    /** 退料仓库ID */
    @Excel(name = "退料仓库ID")
    private Long warehouseId;

    /** 仓库名称 */
    @Excel(name = "仓库名称")
    private String warehouseName;

    /** 退料人ID */
    @Excel(name = "退料人ID")
    private Long returnerId;

    /** 退料人姓名 */
    @Excel(name = "退料人姓名")
    private String returnerName;

    /** 审批人ID */
    @Excel(name = "审批人ID")
    private Long approverId;

    /** 审批人姓名 */
    @Excel(name = "审批人姓名")
    private String approverName;

    /** 审批时间 */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @Excel(name = "审批时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
    private Date approveTime;

    /** 退料原因 */
    @Excel(name = "退料原因")
    private String returnReason;

    /** 状态 (待退料, 已退料, 部分退料, 已取消) */
    @Excel(name = "状态")
    private String status;

    /** 退料总金额 */
    @Excel(name = "退料总金额")
    private BigDecimal totalAmount;

    /** 退料单明细信息 */
    private List<MesProductionReturnDetail> returnDetailList;

    public void setReturnId(Long returnId) 
    {
        this.returnId = returnId;
    }

    public Long getReturnId() 
    {
        return returnId;
    }
    public void setReturnCode(String returnCode) 
    {
        this.returnCode = returnCode;
    }

    public String getReturnCode() 
    {
        return returnCode;
    }
    public void setPickingId(Long pickingId) 
    {
        this.pickingId = pickingId;
    }

    public Long getPickingId() 
    {
        return pickingId;
    }
    public void setPickingCode(String pickingCode) 
    {
        this.pickingCode = pickingCode;
    }

    public String getPickingCode() 
    {
        return pickingCode;
    }
    public void setWorkOrderId(Long workOrderId) 
    {
        this.workOrderId = workOrderId;
    }

    public Long getWorkOrderId() 
    {
        return workOrderId;
    }
    public void setWorkOrderCode(String workOrderCode) 
    {
        this.workOrderCode = workOrderCode;
    }

    public String getWorkOrderCode() 
    {
        return workOrderCode;
    }
    public void setReturnDate(Date returnDate) 
    {
        this.returnDate = returnDate;
    }

    public Date getReturnDate() 
    {
        return returnDate;
    }
    public void setWarehouseId(Long warehouseId) 
    {
        this.warehouseId = warehouseId;
    }

    public Long getWarehouseId() 
    {
        return warehouseId;
    }
    public void setWarehouseName(String warehouseName) 
    {
        this.warehouseName = warehouseName;
    }

    public String getWarehouseName() 
    {
        return warehouseName;
    }
    public void setReturnerId(Long returnerId) 
    {
        this.returnerId = returnerId;
    }

    public Long getReturnerId() 
    {
        return returnerId;
    }
    public void setReturnerName(String returnerName) 
    {
        this.returnerName = returnerName;
    }

    public String getReturnerName() 
    {
        return returnerName;
    }
    public void setApproverId(Long approverId) 
    {
        this.approverId = approverId;
    }

    public Long getApproverId() 
    {
        return approverId;
    }
    public void setApproverName(String approverName) 
    {
        this.approverName = approverName;
    }

    public String getApproverName() 
    {
        return approverName;
    }
    public void setApproveTime(Date approveTime) 
    {
        this.approveTime = approveTime;
    }

    public Date getApproveTime() 
    {
        return approveTime;
    }
    public void setReturnReason(String returnReason) 
    {
        this.returnReason = returnReason;
    }

    public String getReturnReason() 
    {
        return returnReason;
    }
    public void setStatus(String status) 
    {
        this.status = status;
    }

    public String getStatus() 
    {
        return status;
    }
    public void setTotalAmount(BigDecimal totalAmount) 
    {
        this.totalAmount = totalAmount;
    }

    public BigDecimal getTotalAmount() 
    {
        return totalAmount;
    }

    public List<MesProductionReturnDetail> getReturnDetailList()
    {
        return returnDetailList;
    }

    public void setReturnDetailList(List<MesProductionReturnDetail> returnDetailList)
    {
        this.returnDetailList = returnDetailList;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
            .append("returnId", getReturnId())
            .append("returnCode", getReturnCode())
            .append("pickingId", getPickingId())
            .append("pickingCode", getPickingCode())
            .append("workOrderId", getWorkOrderId())
            .append("workOrderCode", getWorkOrderCode())
            .append("returnDate", getReturnDate())
            .append("warehouseId", getWarehouseId())
            .append("warehouseName", getWarehouseName())
            .append("returnerId", getReturnerId())
            .append("returnerName", getReturnerName())
            .append("approverId", getApproverId())
            .append("approverName", getApproverName())
            .append("approveTime", getApproveTime())
            .append("returnReason", getReturnReason())
            .append("status", getStatus())
            .append("totalAmount", getTotalAmount())
            .append("remark", getRemark())
            .append("createBy", getCreateBy())
            .append("createTime", getCreateTime())
            .append("updateBy", getUpdateBy())
            .append("updateTime", getUpdateTime())
            .append("returnDetailList", getReturnDetailList())
            .toString();
    }
}